package com.kejy.service.impl;

import com.kejy.entity.Auction;
import com.kejy.mapper.AuctionMapper;
import com.kejy.util.MyBatisUtil;

import java.util.List;

public class AuctionMapperImpl implements AuctionMapper {
    private AuctionMapper auctionMapper = MyBatisUtil.createSqlSession().getMapper(AuctionMapper.class);

    @Override
    public int addAuction(Auction auction) {
        return auctionMapper.addAuction(auction);
    }

    @Override
    public List<Auction> selectByCondition(Auction auction) {
        return auctionMapper.selectByCondition(auction);
    }

    @Override
    public Auction selectById(Integer auctionId) {
        return auctionMapper.selectById(auctionId);
    }

    @Override
    public int updateAuction(Auction auction) {
        return auctionMapper.updateAuction(auction);
    }

    @Override
    public int deleteAuction(Integer auctionId) {
        return auctionMapper.deleteAuction(auctionId);
    }
}
